//2009/08/16 18:48:23
#include <iostream>
#include <string>
#include <vector>
#include <map>
#include <queue>
#include <sstream>
#include <algorithm>

using namespace std;

class ChatTranscript
{
public:
    int howMany(vector <string> trans, string name)
    {
		int cost = 0;
		for(int i=0; i<trans.size(); i++)
		{
			if(trans[i].substr(0, name.size()+1).compare(name+":") == 0) cost ++;
		}
		return cost;
    }
};
